@extends('admin.app')

@section('breadcrumb')
    <div class="bg-light lter b-b wrapper-md">
        <ol class="breadcrumb bg-light lter m-n no-padder">
            <li><a href="{{ admin_action('HomeController@index') }}">主页</a></li>
            <li>业务管理</li>
            <li><a href="{{ admin_action('Business\OrganizationalUserManagementController@index') }}">机构用户管理</a></li>
            <li class="active">新增机构用户</li>
        </ol>
    </div>
@endsection

@section('content')
    <div class="panel panel-default">
        <div class="panel-heading font-bold">
            设置经办人信息
        </div>
        <div class="panel-body">
            <form enctype="multipart/form-data" class="form-horizontal form-validation"
                  action="{{ admin_action('Business\OrganizationalUserManagementController@saveAgentInfo',[$org]) }}"
                  method="post">
                {{ csrf_field() }}
                <label>{{ $org->company_name }}</label>
                <div class="line line-dashed b-b line-lg"></div>
                <div class="form-group">
                    <label class="col-lg-2 control-label">经办人姓名*</label>
                    <div class="col-lg-4">
                        <input type="text" class="form-control" name="agent_name" value="{{ old('agent_name') }}"
                               placeholder="请输入经办人姓名" data-rule-required="true" data-rule-maxLength="90">
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-lg-2 control-label">经办人身份证*</label>
                    <div class="col-lg-4">
                        <input type="tel" class="form-control" name="agent_license_no" value="{{ old('agent_license_no') }}"
                               placeholder="请填写经办人身份证号码" data-rule-id_card="true" data-rule-required="true"
                               data-rule-maxLength="18">
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-lg-2 control-label">经办人手机号*</label>
                    <div class="col-lg-4">
                        <input type="tel" class="form-control" name="agent_mobile"
                               value="{{ old('agent_mobile') }}" placeholder="请填写经办人手机号码" data-rule-required="true"
                               data-rule-maxLength="20">
                    </div>
                </div>
                <div class="line line-dashed b-b line-lg"></div>
                <div class="form-group">
                    <div class="col-lg-4 col-lg-offset-2">
                        <a href="{{ admin_action('Business\OrganizationalUserManagementController@index') }}"
                           class="btn btn-default">返&nbsp;回</a>
                        <button type="submit" class="btn btn-primary">保&nbsp;存</button>
                    </div>
                </div>
            </form>
        </div>
    </div>
@endsection
@section('scripts')
    @include('admin.partials.ueditor')
    <script>
        jQuery('.datetimepicker_mask').datetimepicker({
            timepicker: false,
            mask: '9999-19-39',
            format: 'Y-m-d'
        });
    </script>
@endsection